<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <style>
    .box {
      width: 100%;
      height: 80px;
      border: 1px solid #ccc;
    }
    .item {
      width: 50%;
      height: 100%;
      float: left;
    }
    /* 当浮动元素在父级元素内被强制换行 使用margin-left向左margin的时候会重新移动到上一行 */
    .three {
      margin-left: -100%;
    }
  </style>
  <body>
    <div class="box">
      <div class="item">1</div>
      <div class="item">2</div>
      <div class="item three">3</div>
    </div>
  </body>
</html>
